const errcode = require('../utils/errcode')

exports.loginRequired = async (ctx, next) => {
    if (!ctx.login) return ctx.error(errcode.NO_LOGIN)

    await next()
}
